package com.rc.saas.tenant.vo.ugs;

import com.rc.saas.tenant.model.ugs.UgsMemberSuperLevel;

import java.util.Date;

/**
 * @author frog
 * @date 2021/4/9
 */
public class UgsMemberSuperLevelResultVo extends UgsMemberSuperLevel {
    private String nickname;
    private String mobile;
    private Long memberId;

    private String userStatus = "进行中";

    public String getUserStatus() {
        long time = System.currentTimeMillis();
        if ("1".equals(getStatus())) {
            return "已失效";
        }else if (getBeginTime().getTime() < time && getEndTime().getTime() > time) {
            return "进行中";
        } else if (getBeginTime().getTime() < time) {
            return "已结束";
        }
        return null;
    }

    public void setUserStatus(String userStatus) {
        this.userStatus = userStatus;
    }

    @Override
    public Long getMemberId() {
        return memberId;
    }

    @Override
    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }
}
